package problems.solved;

import java.math.BigInteger;

import problems.Problem;

import utils.Utils;

public class Problem53 extends Problem<Integer> {
	public static void main(String[] args) {
		Problem53 problem53 = new Problem53();
		problem53.runTimed();
		problem53.printResult();
	}

	@Override
	public void run() {
		int result = 0;
		for (int n = 23; n <= 100; n++) {
			for (int r = 0; r <= n; r++) {
				if (Utils.combinations(n,r).compareTo(BigInteger.valueOf(1000000)) >= 0) {
					result++;
				}
			}
		}
		setResult(result);
	}
}
